<?php

// +----------------------------------------------------------------------
// | H1CMS © OpenSource CMS
// +----------------------------------------------------------------------
// | Copyright (c) 2014-2016 http://www.h1cms.com All rights reserved.
// | Copyright (c) 2014-2016 嘉兴领格信息技术有限公司，并保留所有权利。
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Allen <allen@lg4.cn>
// +----------------------------------------------------------------------

include_once 'functions.php';
include_once 'AddUserValidator.php';

// +----------------------------------------------------------------------
// | 模块初始化
// +----------------------------------------------------------------------
function users_initialize() {
    screen()->setTitle(__('用户管理'));
    screen()->addBreadcrumb(__('用户管理'), url_for('/users/'), '', false);
}

function user_status_span($status) {
    switch ($status) {
        case 1:
            return '<span class="label label-success"><span class="fa fa-check"></span></span>';
        case 0:
            return '<span class="label label-danger"><span class="fa fa-close "></span></span>';
        default:
            return '<span class="label label-default">NONE</span>';
    }
}
